#include<time.h>
#include<stdlib.h>
#include<string.h>
#include <errno.h>

#define NULL ((void *)0)

extern int debug_flag;



#define DEBUG(fmt, args...)     \
if(debug_flag){  \
    do{ \
        time_t timep; \
        time (&timep); \
        char    t[1024]={0}; \
        strncpy(t,ctime(&timep),strlen(ctime(&timep))-1);  \
        fprintf(stdout,"%s\t",t); \
        fprintf(stdout,fmt,##args); \
        fprintf(stdout,"\n"); \
    }while(0); \
}
//  compile error: "warning: backslash-newline at end of file [enabled by default]" 
// insert a null line to end


